<div>
    <div class="row">
        <div class="col-lg-12">
            <div class="ibox ">
                <div class="ibox-title">
                    <h5>
                        <span><vc:i18n name="查询条件" namespace="inspectionTaskManage"></vc:i18n></span>
                    </h5>
                    <div class="ibox-tools" style="top:10px;">
                        <button type="button" class="btn btn-link btn-sm" style="margin-right:10px;" v-on:click="_moreCondition()">
                            {{inspectionTaskManageInfo.moreCondition == true?'隐藏':'更多'}}
                        </button>
                    </div>
                </div>
                <div class="ibox-content">
                    <div class="row">
                        <div class="col-sm-3">
                            <div class="form-group">
                                <input type="text" :placeholder="vc.i18n('请输入执行人','inspectionTaskManage')" v-model="inspectionTaskManageInfo.conditions.planUserName" class=" form-control">
                            </div>
                        </div>
                        <div class="col-sm-4">
                            <div class="form-group">
                                <input type="text" :placeholder="vc.i18n('请输入实际巡检开始时间','inspectionTaskManage')" v-model="inspectionTaskManageInfo.conditions.startTime" class=" form-control startTime">
                            </div>
                        </div>
                        <div class="col-sm-3">
                            <div class="form-group">
                                <input type="text" :placeholder="vc.i18n('请输入实际巡检结束时间','inspectionTaskManage')" v-model="inspectionTaskManageInfo.conditions.endTime" class=" form-control endTime">
                            </div>
                        </div>
                        <div class="col-sm-2">
                            <button type="button" class="btn btn-primary btn-sm" v-on:click="_queryInspectionTaskMethod()">
                                <i class="fa fa-search"></i> <span><vc:i18n name="查询" namespace="inspectionTaskManage"></vc:i18n></span>
                            </button>
                            <button type="button" class="btn btn-white btn-sm" v-on:click="_resetInspectionTaskMethod()">
                                <i class="fa fa-repeat"></i> <span><vc:i18n name="重置" namespace="inspectionTaskManage"></vc:i18n></span>
                            </button>
                        </div>
                    </div>
                    <div class="row" v-show="inspectionTaskManageInfo.moreCondition == true">
                        <div class="col-sm-3">
                            <div class="form-group">
                                <input type="text" :placeholder="vc.i18n('请输入巡检计划ID','inspectionTaskManage')" v-model="inspectionTaskManageInfo.conditions.inspectionPlanId" class=" form-control">
                            </div>
                        </div>
                        <div class="col-sm-4">
                            <div class="form-group">
                                <input type="text" :placeholder="vc.i18n('请输入巡检计划名称','inspectionTaskManage')" v-model="inspectionTaskManageInfo.conditions.inspectionPlanName" class=" form-control">
                            </div>
                        </div>
                        <div class="col-sm-3">
                            <select class="custom-select" v-model="inspectionTaskManageInfo.conditions.state">
                                <option selected value="">{{vc.i18n('请选择巡检状态','inspectionTaskManage')}}</option>
                                <option v-for="(item,index) in inspectionTaskManageInfo.stateTypes" :key="index" :value="item.statusCd">
                                    {{item.name}}
                                </option>
                            </select>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <div class="row">
        <div class="col-lg-12">
            <div class="ibox">
                <div class="ibox-title">
                    <h5>
                        <span><vc:i18n name="巡检任务" namespace="inspectionTaskManage"></vc:i18n></span>
                    </h5>
                    <div class="ibox-tools" style="top:10px;">
                    </div>
                </div>
                <div class="ibox-content">
                    <table class="footable table table-stripped toggle-arrow-tiny" data-page-size="15">
                        <thead>
                            <tr>
                                <th class="text-center">
                                    <span><vc:i18n name="任务编码" namespace="inspectionTaskManage"></vc:i18n></span>
                                </th>
                                <th class="text-center">
                                    <span><vc:i18n name="巡检计划" namespace="inspectionTaskManage"></vc:i18n></span>
                                </th>
                                <th class="text-center">
                                    <span><vc:i18n name="巡检人" namespace="inspectionTaskManage"></vc:i18n></span><br/>
                                    <span><vc:i18n name="开始/结束时间" namespace="inspectionTaskManage"></vc:i18n></span>
                                </th>
                                <th class="text-center">
                                    <span><vc:i18n name="实际巡检时间" namespace="inspectionTaskManage"></vc:i18n></span>
                                </th>
                                <th class="text-center">
                                    <span><vc:i18n name="计划巡检人" namespace="inspectionTaskManage"></vc:i18n></span>
                                </th>
                                <th class="text-center">
                                    <span><vc:i18n name="当前巡检人" namespace="inspectionTaskManage"></vc:i18n></span>
                                </th>
                                <th class="text-center">
                                    <span><vc:i18n name="转移描述" namespace="inspectionTaskManage"></vc:i18n></span>
                                </th>
                                <th class="text-center">
                                    <span><vc:i18n name="巡检方式" namespace="inspectionTaskManage"></vc:i18n></span>
                                </th>
                                <th class="text-center">
                                    <span><vc:i18n name="巡检状态" namespace="inspectionTaskManage"></vc:i18n></span>
                                </th>
                                <th class="text-center">
                                    <span><vc:i18n name="操作" namespace="inspectionTaskManage"></vc:i18n></span>
                                </th>
                            </tr>
                        </thead>
                        <tbody>
                            <tr v-for="inspectionTask in inspectionTaskManageInfo.inspectionTasks">
                                <td class="text-center">{{inspectionTask.taskId}}</td>
                                <td class="text-center">{{inspectionTask.inspectionPlanName}}</td>
                                <td class="text-center">{{inspectionTask.planInsTime}}<br/>{{inspectionTask.planEndTime}}</td>
                                <td class="text-center">{{inspectionTask.actInsTime ? inspectionTask.actInsTime : '-'}}</td>
                                <td class="text-center">{{inspectionTask.originalPlanUserName ? inspectionTask.originalPlanUserName : '-'}}</td>
                                <td class="text-center">{{inspectionTask.planUserName}}</td>
                                <td class="text-center">{{inspectionTask.transferDesc ? inspectionTask.transferDesc : '-'}}</td>
                                <td class="text-center">{{inspectionTask.signTypeName}}</td>
                                <td class="text-center text-danger font-bold" v-if="inspectionTask.state == '20200408'">{{inspectionTask.stateName}}</td>
                                <td class="text-center" v-else>{{inspectionTask.stateName}}</td>
                                <td class="text-center">
                                    <div class="btn-group">
                                        <button class="btn-white btn btn-xs" v-on:click="_openInspectionTaskTransfer(inspectionTask)" v-if="inspectionTask.state == '20200406' || inspectionTask.state == '20200405'"><span><vc:i18n name="流转" namespace="inspectionTaskManage"></vc:i18n></span>
                                    </button>
                                        <button class="btn-white btn btn-xs" v-on:click="_openInspectionTaskDetail(inspectionTask)"><span><vc:i18n name="详情" namespace="inspectionTaskManage"></vc:i18n></span>
                                    </button>
                                        <button class="btn-white btn btn-xs" v-if="vc.hasPrivilege('502022031612550001')" v-on:click="_openDeleteInspectionTask(inspectionTask)"><span><vc:i18n name="删除" namespace="inspectionTaskManage"></vc:i18n></span>
                                    </button>
                                    </div>
                                </td>
                            </tr>
                        </tbody>
                        <tfoot>
                            <tr>
                                <td colspan="11">
                                    <ul class="pagination float-right"></ul>
                                </td>
                            </tr>
                        </tfoot>
                    </table>
                    <!-- 分页 -->
                    <div class="row margin-top-xs">
                        <div class="col-sm-9">
                            <div>
                                巡检任务是根据巡检计划，每天晚上2点钟自动生成，如果没有生成 请确认是否开启了定时任务，或者巡检计划是否设置正确</div>
                        </div>
                        <div class="col-sm-3 float-right">
                            <vc:create path="frame/pagination"></vc:create>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <vc:create path="property/inspectionTaskDetail"></vc:create>
    <vc:create path="property/inspectionTaskTransfer"></vc:create>
    <vc:create path="property/deleteInspectionTask"></vc:create>

</div>
